using Assets.Scripts.GDK;
using System;
using System.Collections;
using UnityEngine;

namespace Brick
{
	public class gdk_coroutine_manager
	{
		public static void init()
		{
			IEnumerator ie = Test01();
			IEnumerator ie2 = Test02();
			gdk_coroutine.Instance.StartCoroutine(ie);
			gdk_coroutine.Instance.StartCoroutine(ie2);
		}

		public static IEnumerator Test01()
		{
			Console.WriteLine("start test 01");
			UnityEngine.Debug.Log(">>>>>>IEnumerator>>>>>>>>>>>>>>>>>>>>>>start test a");
			yield return new gdk_waitForSeconds(5f);
			UnityEngine.Debug.Log(">>>>>>IEnumerator>>>>>>>>>>>>>>>>>>>>>>start test b");
			Console.WriteLine("after 5 seconds");
			yield return new gdk_waitForSeconds(5f);
			UnityEngine.Debug.Log(">>>>>>IEnumerator>>>>>>>>>>>>>>>>>>>>>>start test c");
			Console.WriteLine("after 10 seconds");
		}

		public static IEnumerator Test02()
		{
			Console.WriteLine("start test 02");
			UnityEngine.Debug.Log(">>>>>>IEnumerator>>>>>>>>>>>>>>>>>>>>>>start test d");
			yield return new gdk_waitForFrames(500);
			UnityEngine.Debug.Log(">>>>>>IEnumerator>>>>>>>>>>>>>>>>>>>>>>start test e");
			Console.WriteLine("after 500 frames");
		}
	}
}

